﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="rizhi.aspx.cs" Inherits="Admin_rizhi" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
    <style type="text/css">
        .style7
        {
            width: 100%;
        }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<div style=" width:70%; margin :50px auto">
<asp:GridView ID="GridView2" runat="server" AutoGenerateColumns="False" 
        DataKeyNames="userName,time" 
        onpageindexchanging="GridView2_PageIndexChanging" 
        onrowdatabound="GridView2_RowDataBound" Width="100%" AllowPaging="True" 
        BackColor="White" BorderColor="#999999" BorderStyle="None" BorderWidth="1px" 
        CellPadding="3" GridLines="Vertical">
        <AlternatingRowStyle BackColor="#DCDCDC" />
        <Columns>
            <asp:TemplateField HeaderText="序号">
                <ItemTemplate>
                    <asp:Label ID="Label3" runat="server" Text="Label"></asp:Label>
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField HeaderText="管理员编号">
                <ItemTemplate>
                    <asp:Label ID="Label4" runat="server" Text='<%# Eval("userName") %>'></asp:Label>
                </ItemTemplate>
            </asp:TemplateField>
            <asp:BoundField DataField="ip" HeaderText="客户机ip地址" SortExpression="ip" />
            <asp:BoundField DataField="caozuo" HeaderText="操作" SortExpression="caozuo" />
            <asp:BoundField DataField="time" HeaderText="时间" ReadOnly="True" 
                SortExpression="time" />
      
        </Columns>
        <FooterStyle BackColor="#CCCCCC" ForeColor="Black" />
        <HeaderStyle BackColor="#000084" Font-Bold="True" ForeColor="White" />
        <PagerStyle BackColor="#999999" ForeColor="Black" HorizontalAlign="Center" />
        <PagerTemplate>
                当前第:
                <asp:Label ID="LabelCurrentPage" runat="server" 
                    Text="<%# ((GridView)Container.NamingContainer).PageIndex + 1 %>"></asp:Label>
                页/共:
                <asp:Label ID="LabelPageCount" runat="server" 
                    Text="<%# ((GridView)Container.NamingContainer).PageCount %>"></asp:Label>
                页 
                <asp:LinkButton ID="LinkButtonFirstPage" runat="server" CommandArgument="First" 
                    CommandName="Page" 
                    Visible="<%#((GridView)Container.NamingContainer).PageIndex != 0 %>">首页</asp:LinkButton>
                <asp:LinkButton ID="LinkButtonPreviousPage" runat="server" 
                    CommandArgument="Prev" CommandName="Page" 
                    Visible="<%# ((GridView)Container.NamingContainer).PageIndex != 0 %>">上一页</asp:LinkButton>
                <asp:LinkButton ID="LinkButtonNextPage" runat="server" CommandArgument="Next" 
                    CommandName="Page" 
                    Visible="<%# ((GridView)Container.NamingContainer).PageIndex != ((GridView)Container.NamingContainer).PageCount - 1 %>">下一页</asp:LinkButton>
                <asp:LinkButton ID="LinkButtonLastPage" runat="server" CommandArgument="Last" 
                    CommandName="Page" 
                    Visible="<%# ((GridView)Container.NamingContainer).PageIndex != ((GridView)Container.NamingContainer).PageCount - 1 %>">尾页</asp:LinkButton>
                转到第 
                <asp:TextBox ID="txtNewPageIndex" runat="server" 
                    Text="<%# ((GridView)Container.Parent.Parent).PageIndex + 1 %>" Width="20px" />
                页 
                <asp:LinkButton ID="btnGo" runat="server" CausesValidation="False" 
                    CommandArgument="-2" CommandName="Page" Text="GO" />
        </PagerTemplate>
        <RowStyle BackColor="#EEEEEE" ForeColor="Black" />
        <SelectedRowStyle BackColor="#008A8C" Font-Bold="True" ForeColor="White" />
        <SortedAscendingCellStyle BackColor="#F1F1F1" />
        <SortedAscendingHeaderStyle BackColor="#0000A9" />
        <SortedDescendingCellStyle BackColor="#CAC9C9" />
        <SortedDescendingHeaderStyle BackColor="#000065" />
    </asp:GridView>

    <table class="style7">
        <tr>
            <td width="55%">
                <asp:Label ID="Label5" runat="server" Text="输入管理员编号或操作："></asp:Label>
                <asp:TextBox ID="TextBox1" runat="server" CssClass="tbox" Width="179px"></asp:TextBox>
            </td>
            <td>
                <asp:Button ID="Button1" runat="server" CssClass="btn01" 
                    onclick="Button1_Click" Text="查询" />
            </td>
        </tr>
    </table>

    </div>
    
    </asp:Content>

